A. Omkar and Password | 您所在的位置:网站首页 › tcpdump -G second › A. Omkar and Password |
传送门 A. Omkar and Password time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Lord Omkar has permitted you to enter the Holy Church of Omkar! To test your worthiness, Omkar gives you a password which you must interpret! A password is an array a of n positive integers. You apply the following operation to the array: pick any two adjacent numbers that are not equal to each other and replace them with their sum. Formally, choose an index i such that 1≤i flag=0; cin>>n; cin>>a[1]; for(int i=2;i |
CopyRight 2018-2019 实验室设备网 版权所有 |